//
//  WBTestViewController.swift
//  仿新浪微博
//
//  Created by 罗超 on 2017/5/5.
//  Copyright © 2017年 LuoChao. All rights reserved.
//

import UIKit

class WBTestViewController: WBBaseViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        
        title = "第\(navigationController?.childViewControllers.count ?? 0)页"
    }
    
    @objc fileprivate func nextView() {
        let vc = WBTestViewController()
        
        navigationController?.pushViewController(vc, animated: true)
    }

}

extension WBTestViewController {
    override func setupTableView() {
        super.setupTableView()
        
        navItem.rightBarButtonItem = UIBarButtonItem(title: "下一页", target: self, action: #selector(nextView))
    }
}
